﻿Ext.apply(Kwan, {
    CheckDelete: function (d) {
        if (d.length < 5) {
            this.showNotify(this.PROMPTEDERR_NOSELECT, this.ERR_NOSELECT); return;
        } else { this.showDeleteAllConfirm(Job, d); }
    },

    CellCommand: function (grid, record, command, rowIndex) {
        switch (command) {
            case "Edit": Job.EditInfo(record.data.id); break;
            case "Delete": this.showDeleteConfirm(Job, record.data.id); break;
            default: Job.ChangeState(record.data.id, command); break;
        }
    }
});